<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:ui="http://java.sun.com/jsf/facelets"
      xmlns:h="http://java.sun.com/jsf/html"
      xmlns:f="http://java.sun.com/jsf/core">

    <ui:composition template="/template.xhtml">
        <ui:define name="title">
            <h:outputText value="#{bundle.CreateConfigTitle}"></h:outputText>
        </ui:define>
        <ui:define name="body">
            <h:panelGroup id="messagePanel" layout="block">
                <h:messages errorStyle="color: red" infoStyle="color: green" layout="table"/>
            </h:panelGroup>
            <h:form>
                <h:panelGrid columns="2">
                    <h:outputLabel value="#{bundle.CreateConfigLabel_configName}" for="configName" />
                    <h:inputText id="configName" value="#{configController.selected.configName}" title="#{bundle.CreateConfigTitle_configName}" required="true" requiredMessage="#{bundle.CreateConfigRequiredMessage_configName}"/>
                    <h:outputLabel value="#{bundle.CreateConfigLabel_nbMaxItemEmpruntable}" for="nbMaxItemEmpruntable" />
                    <h:inputText id="nbMaxItemEmpruntable" value="#{configController.selected.nbMaxItemEmpruntable}" title="#{bundle.CreateConfigTitle_nbMaxItemEmpruntable}" required="true" requiredMessage="#{bundle.CreateConfigRequiredMessage_nbMaxItemEmpruntable}"/>
                    <h:outputLabel value="#{bundle.CreateConfigLabel_dureeMiseADisposition}" for="dureeMiseADisposition" />
                    <h:inputText id="dureeMiseADisposition" value="#{configController.selected.dureeMiseADisposition}" title="#{bundle.CreateConfigTitle_dureeMiseADisposition}" required="true" requiredMessage="#{bundle.CreateConfigRequiredMessage_dureeMiseADisposition}"/>
                    <h:outputLabel value="#{bundle.CreateConfigLabel_montantPenaliteParJour}" for="montantPenaliteParJour" />
                    <h:inputText id="montantPenaliteParJour" value="#{configController.selected.montantPenaliteParJour}" title="#{bundle.CreateConfigTitle_montantPenaliteParJour}" required="true" requiredMessage="#{bundle.CreateConfigRequiredMessage_montantPenaliteParJour}"/>
                    <h:outputLabel value="#{bundle.CreateConfigLabel_montantBaseAdhesion}" for="montantBaseAdhesion" />
                    <h:inputText id="montantBaseAdhesion" value="#{configController.selected.montantBaseAdhesion}" title="#{bundle.CreateConfigTitle_montantBaseAdhesion}" required="true" requiredMessage="#{bundle.CreateConfigRequiredMessage_montantBaseAdhesion}"/>
                </h:panelGrid>
                <br />
                <h:commandLink action="#{configController.create}" value="#{bundle.CreateConfigSaveLink}" />
                <br />
                <br />
                <h:commandLink action="#{configController.prepareList}" value="#{bundle.CreateConfigShowAllLink}" immediate="true"/>
                <br />
                <br />
                <h:commandLink value="#{bundle.CreateConfigIndexLink}" action="/index" immediate="true" />
            </h:form>
        </ui:define>
    </ui:composition>

</html>
